//请求后台的方法
import request from '@/request'



//分页查询服务信息
export function getServiceByPage(data){
  return request({
    url:'/service/getServiceByPage',
    method: 'post',
	data
  })
}

//分页查询服务信息
export function exportAllService(data){
  return request({
    url:'/service/exportAllService',
    method: 'post',
	responseType:'blob',
	data
  })
}

//分页查询系统信息
export function selectSystemCallByPage(data){
  return request({
    url:'/service/selectSystemCallByPage',
    method: 'post',
	data
  })
}





//查询服务信息
export function getServiceInfo(params){
  return request({
    url:'/service/getServiceInfo',
    method: 'post',
	params:params
  })
}

//查询消费信息和调用列表
export function getConsumeInfo(data){
  return request({
    url:'/service/getConsumeInfo',
    method: 'post',
	data
  })
}

//分页查询系统信息
export function getSystemInfoByPage(data){
  return request({
    url:'/service/getSystemInfoByPage',
    method: 'post',
	data
  })
}

//分页查询系统信息
export function getSystemInfoByPageNew(data){
  return request({
    url:'/service/getSystemInfoByPageNew',
    method: 'post',
	data
  })
}

//登记系统信息
export function addSystemInfo(data){
  return request({
    url:'/service/addSystemInfo',
    method: 'post',
	data
  })
}

//登记系统信息
export function getTemplateversion(){
  return request({
    url:'/service/getTemplateversion',
    method: 'post'
  })
}



//修改系统信息
export function updateSystemInfo(data){
  return request({
    url:'/service/updateSystemInfo',
    method: 'post',
	data
  })
}

//分页查询消费接口列表
export function getSysInterfaceListByPage(data){
  return request({
    url:'/service/getSysInterfaceListByPage',
    method: 'post',
	data
  })
}

//分页查询服务接口列表
export function getBusInterfaceListByPage(data){
  return request({
    url:'/service/getBusInterfaceListByPage',
    method: 'post',
	data
  })
}

//分页查询服务接口列表
export function getInteractedSystemListByPage(data){
  return request({
    url:'/service/getInteractedSystemListByPage',
    method: 'post',
	data
  })
}

//查询消费(服务)系统数
export function getSystemNums(params){
  return request({
    url:'/service/getSystemNums',
    method: 'post',
	params:params
  })
}

//查询系统信息
export function getSystemInfo(params){
  return request({
    url:'/service/getSystemInfo',
    method: 'post',
	params:params
  })
}

//添加服务调用
export function addServiceInfo(data){
  return request({
    url:'/service/addServiceInfo',
    method: 'post',
	data
  })
}




//导出服务
export function exportService(data){
  return request({
    url:'/service/exportService',
    method: 'post',
	responseType:'blob',
	data
  })
}


//导出服务
export function exportSystemCall(data){
  return request({
    url:'/service/exportSystemCall',
    method: 'post',
	responseType:'blob',
	data
  })
}

//导出服务
export function exportAllSystemCall(data){
  return request({
    url:'/service/exportAllSystemCall',
    method: 'post',
	responseType:'blob',
	data
  })
}



export function exportSystem(data){
  return request({
    url:'/service/exportSystem',
    method: 'post',
	responseType:'blob',
	data
  })
}


/**
 * 饼图数据
 * @param {Object} data
 */
export function getPieData(data){
  return request({
    url:'/service/getPieData',
    method: 'post',
	data
  })
}


/**
 * 首页查询系统数
 */
export function selectSystemNum(){
  return request({
    url:'/service/selectSystemNum',
    method: 'post',
  })
}

/**
 * 首页查询投产服务数
 */
export function selectServiceNum(){
  return request({
    url:'/service/selectServiceNum',
    method: 'post',
  })
}

/**
 * 首页查询TOP10服务数的内联系统
 */
export function selectEsbTop(){
  return request({
    url:'/service/selectEsbTop',
    method: 'post',
  })
}


/**
 * 首页查询TOP10服务数的外联系统
 */
export function selectOesbTop(){
  return request({
    url:'/service/selectOesbTop',
    method: 'post',
  })
}

/**
 * @param {Object} data
 * 查询需求调用信息
 */
export function getConsumeInfoByQmsNo(data){
  return request({
    url:'/service/getConsumeInfoByQmsNo',
    method: 'post',
	data
  })
}

/**
 * @param {Object} data
 * 查询需求调用信息
 */
export function exportCallList(data){
  return request({
    url:'/service/exportCallList',
    method: 'post',
	responseType:'blob',
	data
  })
}




/**
 * 服务删除
 * @param {Object} data
 */
export function deteleService(data){
  return request({
    url:'/service/deteleService',
    method: 'post',
	data
  })
}

/**
 * 系统删除
 * @param {Object} data
 */
export function deteleSystem(data){
  return request({
    url:'/service/deteleSystem',
    method: 'post',
	data
  })
}


export function serviceUpdate(data){
  return request({
    url:'/service/serviceUpdate',
    method: 'post',
	data
  })
}

/**
 * 解除调用
 * @param {Object} data
 */
export function getServiceViewDel(data){
  return request({
    url:'/service/getServiceViewDel',
    method: 'post',
	data
  })
}


/**
 * 测试结果上传
 * @param {Object} data
 */
export function addTestResult(data){
  return request({
    url:'/service/addTestResult',
    method: 'post',
	contentType:'multipart/form-data',
	data
  })
}




/**
 * 查询服务信息-历史服务
 * @param {Object} data
 */
export function getHisByServer(data){
  return request({
    url:'/service/getHisByServer',
    method: 'post',
	data
  })
}


/**
 * 导入
 * @param {Object} data
 */
export function getFileByExcel(data){
  return request({
    url:'/service/getFileByExcel',
    method: 'post',
	contentType:'multipart/form-data',
	data
  })
}


//导出服务
export function exportHisService(data){
  return request({
    url:'/service/exportHisService',
    method: 'post',
	responseType:'blob',
	data
  })
}




export function exportSystemList(data){
  return request({
    url:'/service/exportSystemList',
    method: 'post',
	responseType:'blob',
	data
  })
}



export function exportInterfaceList(data){
  return request({
    url:'/service/exportInterfaceList',
    method: 'post',
	responseType:'blob',
	data
  })
}


